﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;
using Fast.Framework.Models;


namespace Fast.Framework.Interfaces
{

    /// <summary>
    /// 插入接口类
    /// </summary>
    /// <typeparam name="T"></typeparam>
    public interface IInsert<T> where T : class
    {

        /// <summary>
        /// 作为
        /// </summary>
        /// <param name="tableName">表名称</param>
        /// <returns></returns>
        IInsert<T> As(string tableName);

        /// <summary>
        /// 执行异步
        /// </summary>
        /// <returns></returns>
        Task<int> ExecuteAsync();

        /// <summary>
        /// 执行返回自增异步
        /// </summary>
        /// <returns></returns>
        Task<int> ExecuteReturnIdentityAsync();
    }
}
